Such a technique as to previously sample a musical sound at a predetermined sampling frequency, store the resultant sample values in a memory and read out the sample values to reconstruct the musical sound has been known in the art.
In such technique, a so-called fixed sampling system is known as a system for controlling pitch (frequency) of generated musical sound. In this system, with reading rate kept unchanged, the sample values are read out of the memory as being thinned out by a suitable number and the pitch is changed by changing this thinning number.
This fixed sampling system needs a number of sample values for producing such sounds as demanded in musical instruments, which differ slightly in pitch, and, therefore, requires a corresponding capacity of memory. In order to reduce this required memory capacity, the opened Japanese patent specification No. 53-84708 has proposed to reduce the number of sample values and, when an amplitude between adjoining sample values is requested, to obtain it by interpolation. As the method for this interpolation, polynomial interpolation, Lagrange's interpolation and interpolation with filter are known (c.f., for example, "Digital Filter", (1977) Prentice Hall Inc.). The interpolation with filter has been applied to this invention. The principle of this interpolation will not be described further since it is not the object of this application. This principle teaches that the amplitude of waveform at any time point can be obtained by convolution computation if an impulse response waveform of a filter as shown in FIG. 4 as the interpolation filter is stored in terms of amplitude values f.sub.0, f.sub.1, f.sub.2, . . . sampled at a frequency higher by a factor of m (m=4 in the illustrative embodiment) than the sampling frequency of the waveform.
For example, when a waveform as shown in FIG. 5 has amplitude values Y.sub.0, Y.sub.1, Y.sub.2, . . . and it is requested to interpolate an amplitude P.sub.4 as shown in FIG. 5, P.sub.4 can be obtained as follows. EQU P.sub.4 =Y.sub.0 f.sub.1 +Y.sub.1 f.sub.5 +Y.sub.2 f.sub.9 +Y.sub.3 f.sub.13 +Y.sub.4 f.sub.17 +Y.sub.5 f.sub.21 +Y.sub.6 f.sub.25 +Y.sub.7 f.sub.29 ( 1)
Similarly, amplitude P.sub.5 can be obtained as follows. EQU P.sub.5 =Y.sub.1 f.sub.2 +Y.sub.2 f.sub.6 +Y.sub.3 f.sub.10 +Y.sub.4 f.sub.14 +Y.sub.5 f.sub.18 +Y.sub.6 f.sub.22 +Y.sub.7 f.sub.26 +Y.sub.8 f.sub.30
Amplitude P.sub.6 can be obtained as follows. EQU P.sub.6 =Y.sub.2 f.sub.3 +Y.sub.3 f.sub.7 +Y.sub.4 f.sub.11 +Y.sub.5 f.sub.15 +Y.sub.6 f.sub.19 +Y.sub.7 f.sub.23 +Y.sub.8 f.sub.27 +Y.sub.9 f.sub.31
The amplitudes at the other points between the sample values can be interpolated similarly.
It is assumed here, for simplicity of description, that the respective sample values of the impulse response of lowpass filter are sampled at a frequency at most four times the sampling frequency of the waveform as shown in FIG. 5. Therefore, interpolation can be effected at only three points between the sampling points. In practice however, highly accurate interpolation is effected by increasing the sampling frequency. Although it is ideal to obtain the respective sample values of the low-pass filter by sampling the infinite impulse response from time -.infin. to +.infin., those which are sampled by limiting a finite region with a suitable window such as humming window as shown in FIG. 4 can be used sufficiently.
FIG. 8 is a block diagram of a device for effecting interpolation based upon the abovementioned principle, in which 1 denotes a waveform memory which stores the sample values Y.sub.0, Y.sub.1, Y.sub.2, . . . shown in FIG. 5 at its addresses "000", "001", "010", . . . (" " indicates a binary notation).
2 denotes an interpolation table which stores sample values t.sub.0 to t.sub.15 at its addresses "0000" to "1111", respectively, as shown in FIG. 9. While the interpolation table 2 is originally arranged to store f.sub.0 to f.sub.32 as shown in FIG. 4, it is considered to store only f.sub.0 to f.sub.16 at addresses "0000" to "10000" and to turn back the addresses when f.sub.17 to f.sub.32 are needed, since they are symmetric about f.sub.16 as the center. While two's complement of each address may be taken for turning back the addresses, it is necessary for this purpose to invert the respective bits of each address and to add "1" thereto. As shown in FIG. 9, therefore, it stores the sample values t.sub.0 to t.sub.16 which are shifted by a half bit each from the sample values f.sub.0 to f.sub.16, respectively. In this case, it is enough to invert each bit of address for turning back the addresses. Although such half bit shift results in reading of t.sub.0, t.sub.4, t.sub.8, . . . , for example, which shift by a half bit from f.sub.0, f.sub.4, f.sub.8, . . . which are the sample values needed originally, the interpolated amplitude will not deform since the shift is fixed constantly.
4 denotes an address generator for generating an address composed of an integer part of three bits and a decimal part of two bits.
5 denotes a counter for sequentially counting from "000" to "111". An adder adds each count to the integer part of the output of address generator 4 to provide a sum to the waveform memory 1 for use to read the sample values of waveform Y.sub.0, Y.sub.1, . . . . Each count and the decimal part of the output of address generator 4 are supplied through an invertor 6 to interpolation table 2 for use to read the sample values of impulse response t.sub.0, t.sub.1, . . . . The invertor serves to provide interpolation table 2 with inverted decimal part of the address and non-inverted bits of the count excepting the most significant bit (MSB) when MSB is "0" and with non-inverted decimal part of the address and inverted bits of the count excepting MSB when MSB is "1". The invertor 6 may be composed, for example, of four exclusive OR gates.
The sample values read out of waveform memory 1 and interplation table 2 are multiplied by a multiplier 7 and the resultant product is accumulated in an addition register 8.
Now, the description will be made on the operation of this device. Assume now that the address generator 4 is sequentially generating addresses at an increment of "00011", such as "00000", "00011", "00110", . . . and the current output address is "00011". The counter 5 provides first an output count "000" which is added by an adder 10 to the integer part "000" of the output address of address generator 4 and the resultant sum "00000" is applied to waveform memory 1 to read therefrom a sample value Y.sub.0 as shown in FIG. 5. As MSB of the count outut of counter 5 is "0", the decimal part "11" of the address is inverted by invertor 6 and applied to interpolation table 2 as the least significant bits (LSBs), and the bits "00" other than MSB of the count of counter 5 is unchanged and applied to interpolation table 2 as MSBs. Thus, t.sub. 0 is read out from interpolation table 2 and multiplied by Y.sub.0 in multiplier 8 and the resultant product is supplied to addition register 8.
When the count output of counter 5 is incremented by one, the address applied to waveform memory 1 becomes "00100" and the sample value Y.sub.1 is read out therefrom as shown in FIG. 5. On the other hand, the address applied to interpolation table 2 becomes "0100" and t.sub.4 is read out therefrom as shown in FIG. 9 and multiplied by Y.sub.1 in multiplier 7. The resulting product is accumulated by the addition register 8.
Similar operation is repeated every time the count output of counter 5 is incremented by one, before MSB of the count output becomes "1", that is, the count output becomes "100". During the operation, Y.sub.2, Y.sub.3, t.sub.8 and t.sub.12 are read out and products Y.sub.2 t.sub.8 and Y.sub.3 t.sub.12 are calculated and accumulated in addition register 8.
When the count output of counter 5 becomes "100", Y.sub.4 is read out from the address "10000" of waveform memory 1 in the same fashion as above. However, since MSB is "1", the decimal part "11" of the address is applied as it is as LSBs of interpolation table 2, and the bits of count "00" other than MSB are inverted and applied as MSBs of interpolation table 2. Consequently, t.sub.15 is read out from address "1111" of interpolation table 2 as shown in FIG. 9. In the same fashion, thereafter, until the count output of counter 5 becomes "111", t.sub.11, t.sub.7 and t.sub.3 are read out from interpolation table 2, Y.sub.5, Y.sub.6 and Y.sub.7 are read out from waveform memory 1, and products Y.sub.5 t.sub.11, Y.sub.6 t.sub.7 and Y.sub.7 t.sub.3 are calculated by multiplier 7 and accumulated in addition register 8. Consequently, the content of addition register 8 becomes: EQU Y.sub.0 t.sub.0 +Y.sub.1 t.sub.4 +Y.sub.2 t.sub.8 +Y.sub.3 T.sub.12 +Y.sub.4 t.sub.15 +Y.sub.5 t.sub.11 +Y.sub.6 t.sub.7 +Y.sub.7 t.sub.3
and, thus, the amplitude P.sub.4 shown in FIG. 5 is interpolated.
In such prior art, the content of waveform memory 1 is consisting of waveform sample values Y.sub.0, Y.sub.1, Y.sub.2, . . . . In order to save the capacity of memory, it may be recommendable to store the differences between the successive sample values of waveform rather than the sample values themselves. However, when the differences are stored, it is necessary to recover therefrom the original sample values and execute their convolution operation with respective sample values of impulse response, and this requires a complicated circuit configuration.
More particularly, when the differences d.sub.0, d.sub.1, . . . d.sub.7 as shown in FIG. 5 are stored for saving the capacity of memory, the equation (1) representing the amplitude P.sub.4 is rewritten as follows. ##EQU1## In order to obtain interpolation using this equation, it is necessary to accumulate the differences to calculate the respective sample values and, therefore, to use a complicated circuit.